Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(stack reorder): Add command scaffolding #123

Merged
merged 3 commits into from
May 26, 2023

Conversation

twavv
Copy link
Contributor

@twavv twavv commented May 19, 2023

Breaking this into a few parts.

This PR is intended to just define the base scaffolding. Namely, we're just defining the structure of the stack-branch and pick commands (ultimately the goal is to support all the commands from git rebase --interactive in addition to some av specific ones like stack-branch).

This code is not called from anywhere currently.

@aviator-app
Copy link
Contributor

aviator-app bot commented May 19, 2023

Current Aviator status

Aviator will automatically update this comment as the status of the PR changes.
Comment /aviator refresh to force Aviator to re-examine your PR (or learn about other /aviator commands).

This PR was merged using Aviator.

Stack

  1. 👉 feat(stack reorder): Add command scaffolding #123 👈 (this pr)
  2. feat(stack reorder): Implement PickCmd #126

See the real-time status of this PR on the Aviator webapp.


// StackBranchCmd is a command to create a new branch in a stack.
//
// branch <branch-name> [--parent <parent-branch-name>] [--trunk <trunk-branch-name>]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

stack-branch

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, thanks. Originally it was named just branch (before the decision to make it stack-branch to avoid conflicts with rebase's break) and I just missed these. Thanks for catching!

args = args[1:]
switch cmdName {
case "stack-branch", "sb":
return parseBranchCmd(args)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps rename this as parseStackBranchCmd to align with the command name?

@aviator-app aviator-app bot added the blocked label May 26, 2023
@aviator-app
Copy link
Contributor

aviator-app bot commented May 26, 2023

This pull request failed to merge: top queued PR in the stack failed to merge. Remove the blocked label to re-queue.

@twavv twavv added mergequeue and removed blocked labels May 26, 2023
@aviator-app aviator-app bot merged commit 16635c3 into master May 26, 2023
@aviator-app aviator-app bot deleted the travis/mer-2320-av-stack-reorder branch May 26, 2023 15:11
draftcode added a commit that referenced this pull request Dec 20, 2023
When a PR gets closed by "Close #123", usually GitHub marks the PR to be
closed by certain commit. However, this mechanism is not reliable, and
sometimes GitHub doesn't mark it so and just close it. This breaks the
merge commit detection since av-cli doesn't have a way to know it from
GitHub API.

By using git-log, we can figure out whether there's actually a commit
that closes the PRs with this comment. This adds that extra detection
method.

In order to make this work, it moves the timing of git-fetch. This is
needed in order for a local repository to have commits in the upstream
to check the commit messages.
draftcode added a commit that referenced this pull request Jan 3, 2024
When a PR gets closed by "Close #123", usually GitHub marks the PR to be
closed by certain commit. However, this mechanism is not reliable, and
sometimes GitHub doesn't mark it so and just close it. This breaks the
merge commit detection since av-cli doesn't have a way to know it from
GitHub API.

By using git-log, we can figure out whether there's actually a commit
that closes the PRs with this comment. This adds that extra detection
method.

In order to make this work, it moves the timing of git-fetch. This is
needed in order for a local repository to have commits in the upstream
to check the commit messages.
draftcode added a commit that referenced this pull request Jan 3, 2024
When a PR gets closed by "Close #123", usually GitHub marks the PR to be
closed by certain commit. However, this mechanism is not reliable, and
sometimes GitHub doesn't mark it so and just close it. This breaks the
merge commit detection since av-cli doesn't have a way to know it from
GitHub API.

By using git-log, we can figure out whether there's actually a commit
that closes the PRs with this comment. This adds that extra detection
method.

In order to make this work, it moves the timing of git-fetch. This is
needed in order for a local repository to have commits in the upstream
to check the commit messages.
aviator-app bot pushed a commit that referenced this pull request Jan 3, 2024
…es (#218)

When a PR gets closed by "Close #123", usually GitHub marks the PR to be
closed by certain commit. However, this mechanism is not reliable, and
sometimes GitHub doesn't mark it so and just close it. This breaks the
merge commit detection since av-cli doesn't have a way to know it from
GitHub API.

By using git-log, we can figure out whether there's actually a commit
that closes the PRs with this comment. This adds that extra detection
method.

In order to make this work, it moves the timing of git-fetch. This is
needed in order for a local repository to have commits in the upstream
to check the commit messages.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants